package com.hnas.eCard.dao;

import java.util.List;

import com.hnas.core.dao.BaseDao;
import com.hnas.eCard.orm.EntityCardOrderDetail;
import com.hnas.eCard.service.dto.DTOEntityCardOrder;
import com.hnas.eCard.service.dto.DTOEntityCardOrderDetail;
import com.hnas.eCard.service.dto.DTOEntityCardRecord;

public interface EntityCardOrderDetailDao extends BaseDao<EntityCardOrderDetail>{

	/**
	 * 添加/修改售卡订单详情记录
	 * @Title: saveOrUpdate  
	 * @Description:  
	 * @param vo
	 * @return
	 * @throws
	 */
	EntityCardOrderDetail saveOrUpdate(DTOEntityCardOrderDetail dto);
	/**
	 * 根据订单编号查询售卡订单详情记录
	 * @Title: findByOrderNo  
	 * @Description:  
	 * @param orderNo
	 * @return
	 * @throws
	 */
	EntityCardOrderDetail findByOrderNo(String orderNo);
	/**
	 * 根据订单编号查询售卡订单记录（包含详情）
	 * @Title: findByOrderNo  
	 * @Description:  
	 * @param orderNo
	 * @return
	 * @throws
	 */
	DTOEntityCardOrder findEntityCardOrderByOrderNo(String orderNo);
	/**
	 * 根据微信交易流水号查询售卡订单记录（包含详情）
	 * @Title: findSaleCardOrderBySwiftNumber  
	 * @Description:  
	 * @param swiftNumber
	 * @return
	 * @throws
	 */
	DTOEntityCardOrder findEntityCardOrderBySwiftNumber(String swiftNumber);
	/**
	 * 根据微信交易流水号查询售卡交易记录（包含详情）
	 * @Title: findSaleCardRecordBySwiftNumber  
	 * @Description:  
	 * @param swiftNumber
	 * @return
	 * @throws
	 */
	DTOEntityCardRecord findEntityCardRecordBySwiftNumber(String swiftNumber);
	/**
	 * 根据账户id获取购实体卡订单
	 * @Title: findEntityOrderListByAccId  
	 * @Description:  
	 * @param accId
	 * @return
	 * @throws
	 */
	List<DTOEntityCardOrder> findEntityOrderListByAccId(String accId);
	boolean confirmConsume(String accId, String orderNo, String mrchId, String termNo, String dealDate);
	DTOEntityCardOrder getEntityByOrderNo(String orderNo);
	DTOEntityCardOrder getCommoditByOrderNo(String orderNo);
}
